package com.world.rickcloudendpoint.service.uuid;

import org.springframework.stereotype.Service;

import java.util.concurrent.atomic.AtomicLong;

/**
 * @description: uuid唯一标识生成器
 * @author: jlsong
 * @date: 2021/12/24 21:32:50
 * @version: 1.0
 */
@Service
public class LongIdGenerator {
    protected static AtomicLong id_gen = new AtomicLong(0);

    public static long generateId(){
        return id_gen.incrementAndGet();
    }
}
